import iconFont from '@/assets/iconFont/iconfont.less';
import { theme } from 'antd';
import cls from 'classnames';

const { useToken } = theme;
export default function CommonIcon({ handClick }) {
  const { token } = useToken();
  let color = token.colorPrimary;
  return (
    <span
      className={cls([iconFont.iconfont, 'anticon', 'btn-iconfont'])}
      style={{
        color,
        marginInlineEnd: 4,
        cursor: 'pointer',
        width: 21,
        height: 21,
      }}
      dangerouslySetInnerHTML={{ __html: '&#xe8ad' }}
      onClick={handClick}
    ></span>
  );
}
